﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace ShutUp
{
    public partial class myNamePopUpForm : Form
    {
        public myNamePopUpForm()
        {
            InitializeComponent();
        }
        private readonly ShutUp _ShutUp = new ShutUp();
        private static Styx.WoWInternals.WoWObjects.LocalPlayer Me { get { return Styx.StyxWoW.Me; } }

        private void myNamePopUpForm_Load(object sender, EventArgs e)
        {
            VersionLabel.Text = "v" + _ShutUp.Version.ToString();
            BarryD.Image = Image.FromFile(Application.StartupPath + "\\Plugins\\ShutUp\\Forms\\BarryDurex");
            Icon = ChatHelper.convertToIcon(BarryD.Image, Color.Empty);
            timer1.Start();
            lb_atName.Text = string.Format("at {0} - {1} - ({2}) - ({3})", Me.Name, Me.Race, Me.Level, DateTime.Now.ToShortTimeString());
        }

        private void timer1_Tick(object sender, EventArgs e)
        {
            if (lb_text.ForeColor == Color.DarkRed)
                lb_text.ForeColor = Color.Red;
            else
                lb_text.ForeColor = Color.DarkRed;
        }

        private void btn_close_Click(object sender, EventArgs e)
        {
            this.Dispose();
        }
    }
}
